package com.ruoyi.system.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.OrderDtoMapper;
import com.ruoyi.system.domain.OrderDto;
import com.ruoyi.system.service.IOrderDtoService;

/**
 * 【请填写功能名称】Service业务层处理
 * 
 * @author ruoyi
 * @date 2023-07-28
 */
@Service
public class OrderDtoServiceImpl implements IOrderDtoService 
{
    @Autowired
    private OrderDtoMapper orderDtoMapper;

    /**
     * 查询【请填写功能名称】
     * 
     * @param orderId 【请填写功能名称】主键
     * @return 【请填写功能名称】
     */
    @Override
    public OrderDto selectOrderDtoByOrderId(Long orderId)
    {
        return orderDtoMapper.selectOrderDtoByOrderId(orderId);
    }

    /**
     * 查询【请填写功能名称】列表
     * 
     * @param orderDto 【请填写功能名称】
     * @return 【请填写功能名称】
     */
    @Override
    public List<OrderDto> selectOrderDtoList(OrderDto orderDto)
    {
        return orderDtoMapper.selectOrderDtoList(orderDto);
    }

    /**
     * 新增【请填写功能名称】
     * 
     * @param orderDto 【请填写功能名称】
     * @return 结果
     */
    @Override
    public int insertOrderDto(OrderDto orderDto)
    {
        orderDto.setCreateTime(DateUtils.getNowDate());
        return orderDtoMapper.insertOrderDto(orderDto);
    }

    /**
     * 修改【请填写功能名称】
     * 
     * @param orderDto 【请填写功能名称】
     * @return 结果
     */
    @Override
    public int updateOrderDto(OrderDto orderDto)
    {
        return orderDtoMapper.updateOrderDto(orderDto);
    }

    /**
     * 批量删除【请填写功能名称】
     * 
     * @param orderIds 需要删除的【请填写功能名称】主键
     * @return 结果
     */
    @Override
    public int deleteOrderDtoByOrderIds(Long[] orderIds)
    {
        return orderDtoMapper.deleteOrderDtoByOrderIds(orderIds);
    }

    /**
     * 删除【请填写功能名称】信息
     * 
     * @param orderId 【请填写功能名称】主键
     * @return 结果
     */
    @Override
    public int deleteOrderDtoByOrderId(Long orderId)
    {
        return orderDtoMapper.deleteOrderDtoByOrderId(orderId);
    }

    @Override
    public OrderDto selectOrderByOrderId(Long orderId) {
        return orderDtoMapper.selectOrderByOrderId(orderId);
    }
}
